package runnerworm.ui;

import java.util.*;
import runnerworm.core.*;
import java.awt.*;
import javax.swing.*;

/**
 * <p>Title: UserInterfaceListener</p>
 * <p>Description: This will be the interface responsable for the event
 * launched by the user interface. It will be implemented to provide what
 * to do when the user selects something on the menu.</p>
 * @author Guilherme Mauro Germoglio Barbosa
 */
public interface UserInterfaceListener
    extends EventListener {

  /**
   * Provides what do to when the "new game" option is selected.
   * @param gameOptions The game's options.
   * @param score The game's score label.
   * @param panel Where the game will be shown.
   */
  void newGameSelected(GameOptions gameOptions, JLabel score, JPanel panel);

  /**
   * Provides what to do when the "options" option is selected.
   * @param evt The OptionsEvent captured.
   */
  void optionsSelected(OptionsEvent evt);

  /**
   * Provides what to do when the "high scores" option is selected.
   * @param evt The HighScoresEvent captured.
   */
  void highScoresSelected(HighScoresEvent evt);

  /**
   * Provides what to do when the "Quit" option is selected.
   * @param evt The QuitGameEvent captured.
   */
  void quitSelected(QuitGameEvent evt);

  /**
   * Provides what to do when the "about" option is selected.
   * @param evt The AboutEvent captured.
   */
  void aboutSelected(AboutEvent evt);

  /**
   * Provides what to do when the "help" option is selected.
   * @param evt The HelpEvent captured.
   */
  void helpSelected(HelpEvent evt);

  /**
   * Provides what to do when the user wants the worm going up.
   */
  void wormGoesUp();

  /**
   * Provides what to do when the user wants the worm going down.
   */
  void wormGoesDown();

  /**
   * Provides what to do when the player gives his/her name.
   * @param playerName The player's name.
   */
  void setPlayerName(String playerName);

}
